#include <iostream>
#include <cmath>
using namespace std;

#ifndef COMPLEX_H
#define COMPLEX_H

class Complex
{
    public:
        friend ostream& operator<< (ostream&, Complex);
        friend Complex operator+ (double, Complex);
        friend Complex operator- (double, Complex);

        Complex (double = 0.0, double = 0.0);
        Complex& operator+ (Complex);
        Complex& operator- (Complex);
        Complex& operator+ (double);
        Complex& operator- (double);

        double& real ();
        double& imagine ();

    private:
        double realPart;
        double imagePart;
};

#endif
